
Defines | |
| #define | CMDLINESIZE 256 |
| Maximum command line size in characters. | |
| #define | SERIALMSGSIZE 128 |
| Maximum serial message size in bytes. | |
Functions | |
| int | help_fun (char *msg, char *buf, int curindex, int len, int16_t g_sockfd) |
| int | processCmd (char *cmd, int curindex, int len, int16_t g_sockfd) |
| process shell command | |
| void | prompt (int16_t g_sockfd) |
| this function sends a prompt to a TCP socket | |
| #define CMDLINESIZE 256 |
Maximum command line size in characters.
| #define SERIALMSGSIZE 128 |
Maximum serial message size in bytes.
| int help_fun | ( | char * | msg, | |
| char * | buf, | |||
| int | curindex, | |||
| int | len, | |||
| int16_t | g_sockfd | |||
| ) |
| int processCmd | ( | char * | cmd, | |
| int | curindex, | |||
| int | len, | |||
| int16_t | sockfd | |||
| ) |
process shell command
processCmd
Process command in command buffer cmd[] starting at cmd[curindex] and ending at cmd[len] Dispatches to individual command handlers
| cmd | is the pointer to the string of shell command | |
| curindex | is always zero | |
| len | is the number of characters in the shell command | |
| sockfd | is the TCP socket descriptor |
negative integers : Close

| void prompt | ( | int16_t | sockfd | ) |
this function sends a prompt to a TCP socket
prompt
| sockfd | is the descriptor of the socket |

1.5.5